package com.summer.safe.quartz.entity;

import com.summer.safe.base.BaseEntity;

/**
 * 定时任务调度 Entity
 *
 * @author lm
 * @date 2020-07-23 14:27:23
 */
public class QuartzJob extends BaseEntity<QuartzJob> {
    private static final long serialVersionUID = 1L;

    //启动
    public static final String STATUS_RUNNING = "0";
    //暂停
    public static final String STATUS_NOT_RUNNING = "1";
    //恢复
    public static final String STATUS_RECOVERY_RUNNING = "2";
    //停止
    public static final String STATUS_STOP_RUNNING = "3";
    //执行并发
    public static final String CONCURRENT_IS = "0";
    //不执行并发
    public static final String CONCURRENT_NOT = "1";

    /** 任务的目标 */
    public static final String TASK_TARGET = "TASK_TARGET";
    /**
     * 任务名称
     */
    public static final String TASK__NAME = "TASK__NAME";


    /**
     *任务名称
     */
    private String jobName;

    /**
     *任务组名
     */
    private String jobGroup;

    /**
     *任务执行时调用的类
     */
    private String beanClass;

    /**
     *任务调用的方法名
     */
    private String methodName;

    /**
     *cron执行表达式
     */
    private String cronExpression;

    /**
     *参数
     */
    private String params;

    /**
     *并发执行（0是 1否）
     */
    private String concurrent;

    /**
     *任务状态（0运行 1暂停 2恢复 3停止）
     */
    private String status;


    public QuartzJob() {
        super();
        this.concurrent=CONCURRENT_NOT;
        this.status=STATUS_RUNNING;
    }

    public QuartzJob(String id,String status) {
        this.id=id;
        this.status=status;
    }

    public String getJobName() {
        return jobName;
    }

    public void setJobName(String jobName) {
        this.jobName = jobName;
    }

    public String getJobGroup() {
        return jobGroup;
    }

    public void setJobGroup(String jobGroup) {
        this.jobGroup = jobGroup;
    }

    public String getBeanClass() {
        return beanClass;
    }

    public void setBeanClass(String beanClass) {
        this.beanClass = beanClass;
    }

    public String getMethodName() {
        return methodName;
    }

    public void setMethodName(String methodName) {
        this.methodName = methodName;
    }

    public String getCronExpression() {
        return cronExpression;
    }

    public void setCronExpression(String cronExpression) {
        this.cronExpression = cronExpression;
    }


    public String getParams() {
        return params;
    }

    public void setParams(String params) {
        this.params = params;
    }

    public String getConcurrent() {
        return concurrent;
    }

    public void setConcurrent(String concurrent) {
        this.concurrent = concurrent;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }




}
